<!DOCTYPE html>
<html>
<head>
    {include file="common/meta"}
</head>
<body>
    <div class="mui-content">
        <div id="slider" class="mui-slider">
            <div class="mui-slider-group mui-slider-loop">
                <!-- 额外增加的一个节点(循环轮播：第一个节点是最后一张轮播) -->
                <div class="mui-slider-item mui-slider-item-duplicate">
                    <a href="#">
                        <img src="\assets\index\images\video4.png">
                        <p class="mui-slider-title">web前端开发</p>
                    </a>
                </div>
                {foreach $toplist as $img}
                <div class="mui-slider-item">
                    <a href="#">
                        <img src="{$img['thumbs']}">
                        <p class="mui-slider-title">{$img['title']}</p>
                    </a>
                </div>
                {/foreach}
                <!-- 额外增加的一个节点(循环轮播：最后一个节点是第一张轮播) -->
                <div class="mui-slider-item mui-slider-item-duplicate">
                    <a href="#">
                        <img src="\assets\index\images\video2.png">
                        <p class="mui-slider-title">React实战模拟</p>
                    </a>
                </div>
            </div>
            <div class="mui-slider-indicator mui-text-right">
                <div class="mui-indicator mui-active"></div>
                <div class="mui-indicator"></div>
                <div class="mui-indicator"></div>
                <div class="mui-indicator"></div>
                <div class="mui-indicator"></div>
            </div>
        </div>
    </div>
    <form method="get" action="{:url('/index/subject/search')}">
        <div class="mui-content">
            <!-- MUI 搜索框 -->
            <div class="mui-input-row mui-search" id="searchForm">
                <input type="search" name="indexSearch" id="searchInput" onkeyup="enterSearch(event)" class="mui-input-clear" placeholder="搜索课程">
            </div>
        </div>
    </form>
    <div class="mui-content" style="background-color:#fff">
        {foreach $catelist as $item}
        <h5 style="background-color:#efeff4">{$item.name}<a href="/assets/index/html/Video-list.html" style="float:right; margin-right:10px;">更多</a></h5>
        <ul class="mui-table-view mui-grid-view">
            {foreach $item.subject as $subject}
            <li class="mui-table-view-cell mui-media mui-col-xs-6">
                <a href="{:url('/index/subject/subject',['subid' => $subject['id']])}">
                    <img class="mui-media-object" src="{$subject.thumbs}">
                    <div class="mui-media-body">{$subject.title}</div>
                </a>
            </li>
            {/foreach}
        </ul>
        {/foreach}
    </div>
    
    <br />
    <div class="weui-footer">
        <p class="weui-footer__text">没有更多了</p>
    </div>
    {include file="common/footer"}
</body>
</html>
{include file="common/script"}
<script>
</script>
